package com.yinhai.uid.utils;

import javax.ws.rs.client.Client;
import javax.ws.rs.client.ClientBuilder;
import javax.ws.rs.client.Invocation;
import javax.ws.rs.client.WebTarget;
import javax.ws.rs.core.MediaType;

/**
 * @author taojie
 * @Date: 2018/12/30 14:57
 * @Description:
 */
public class jerseyUtils {

	public static Object sendGet(String url) {
		Client client = ClientBuilder.newClient();
		WebTarget webTarget = client.target(url);
		Invocation.Builder builder = webTarget.request(MediaType.APPLICATION_JSON);
		Object result = builder.get(Object.class);
		return result;
	}
}
